Conversation
# Why `Asset.getUri()` returns a different rendition per media type on iOS. Images come back as they currently look in Photos, videos as originally captured. So a video edited in Photos resolves without its edits, and so does `AssetInfo.uri`. The legacy API returns the current version for video, so migrating to the current API silently changes what you read. Found while reviewing #48248, which fixes the same bug in legacy `expo-file-system`. # How - Added a `version` option to `getUri()`, defaulting to the current rendition for all media types. - For video, this sets `PHVideoRequestOptions.version`. - For an original image, we claim the adjustment data so Photos returns the pre-edit image. - Android has no such renditions, so it accepts the option and ignores it. # Test Plan - iOS NCL (updated screen) - iOS test-suite (new tests) # Checklist - [x] I added a `changelog.md` entry and rebuilt the package sources according to [this short guide](https://github.com/expo/expo/blob/main/CONTRIBUTING.md#-before-submitting) - [ ] This diff will work correctly for `npx expo prebuild` & EAS Build (eg: updated a module plugin). - [x] Conforms with the [Documentation Writing Style Guide](https://github.com/expo/expo/blob/main/guides/Expo%20Documentation%20Writing%20Style%20Guide.md)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
See Commits and Changes for more details.
Created by
pull[bot] (v2.0.0-alpha.4)
Can you help keep this open source service alive? 💖 Please sponsor : )